
export const timeFormat=(timestr)=>{
	let d=new Date(timestr)
	console.log(d)
	let y=d.getFullYear()
	let M=d.getMonth()+1;
	let day=d.getDate() +""
	day=day.padStart(2,"0")
	let h=d.getHours()+""
	h=h.padStart(2,"0")
	
	let m=d.getMinutes()+""
	m=m.padStart(2,"0")
	let s=d.getSeconds()+""
	s=s.padStart(2,"0")
	return `${y}-${M}-${day} ${h}:${m}:${s}`
	
}

export const dateFormat=(timestr)=>{
	let d=new Date(timestr*1000)
	console.log(d)
	let y=d.getFullYear()
	let M=d.getMonth()+1+"";
	M=M.padStart(2,"0")
	let day=d.getDate() +""
	day=day.padStart(2,"0")
 
	return `${y}-${M}-${day}	`
}